<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
    <?php include_http_metas() ?>
    <?php include_metas() ?>
    <?php include_title() ?>
    <link rel="shortcut icon" href="/favicon.ico" />
    <?php include_stylesheets() ?>
    <?php include_javascripts() ?>
  </head>
  <body>
    <div id="viewport">
      <h1> <?php echo link_to("Idea-Center","@homepage")?> </h1>
      <div id="notifications">
        <?php if(has_slot('notifications')):?>
          <?php echo include_slot('notifications')?>
        <?php endif ?>
      </div>
      <div id="container_section">
        <div id="left_section">
          <!-- This section is devoted to user context op -->
          <?php if(!$sf_user->isAuthenticated()):?>
            <div id="log_form">
              <?php echo include_partial('user/login',array('form' => new sfGuardFormSignin()))?>
            </div>
            Dont have an account yet?
            <?php echo link_to('Register now!','user/new')?>
          <?php else:?>
            <div id="user_info">
             <?php echo include_partial('user/info')?>
             <?php echo include_partial('idea/control_panel')?>
           </div>
          <?php endif?>
        </div>
        <div id="right_section">
          <!-- Main information peace -->
          <div id="operation_section">
            <ul class="ul_menu">
            <!-- Operations for the idea -->
              <?php if (has_slot('operations')):?>
                <?php include_slot('operations')?>
              <?php endif?>
            </ul>
          </div>
          <div id="main_section">
            <div id="content">
              <?php echo $sf_content ?>
            </div>
          </div>
          <div id="next_item">
            <?php if(has_slot('bottom_action')):?>
              <?php include_slot('bottom_action')?>
            <?else:?>
              <?php echo link_to('See next idea','random_idea')?>
            <?php endif?>
            <!-- Here should be a big button to the next idea -->
          </div>
        </div>
      </div>
    </div>
  </body>
</html>
